package com.java2401.springbootv2.pojo;

//import lombok.Data;
//import lombok.ToString;
//import org.springframework.boot.context.properties.ConfigurationProperties;
//import org.springframework.stereotype.Component;
//
//import java.sql.Date;
//import java.util.List;
//import java.util.Map;
//import java.util.Set;
//
//@Component // 表示 user 是容器中的组件
//@ConfigurationProperties(prefix = "person") // 跟配置文件的person前缀绑定
//@Data
//@ToString
//public class User {
//    private String userName;
//    private Boolean boss;
//    private Date birth;
//    private Integer age;
//    private Pet pet;
//    private String[] interests;
//    private List<String> animal;
//    private Map<String, Object> score;
//    private Set<Double> salarys;
//    private Map<String, List<Pet>> allPets;
//}

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

public class User {
    private Integer id;

    private Integer userId;

    private String userName;

    private String userPwd;

    private String userRealname;

    private String userImg;

    private Integer userAge;

    public User() {
    }

    public User(Integer id, Integer userId, String userName, String userPwd, String userRealname, String userImg, Integer userAge) {
        this.id = id;
        this.userId = userId;
        this.userName = userName;
        this.userPwd = userPwd;
        this.userRealname = userRealname;
        this.userImg = userImg;
        this.userAge = userAge;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", userId=" + userId +
                ", userName='" + userName + '\'' +
                ", userPwd='" + userPwd + '\'' +
                ", userRealname='" + userRealname + '\'' +
                ", userImg='" + userImg + '\'' +
                ", userAge=" + userAge +
                '}';
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName == null ? null : userName.trim();
    }

    public String getUserPwd() {
        return userPwd;
    }

    public void setUserPwd(String userPwd) {
        this.userPwd = userPwd == null ? null : userPwd.trim();
    }

    public String getUserRealname() {
        return userRealname;
    }

    public void setUserRealname(String userRealname) {
        this.userRealname = userRealname == null ? null : userRealname.trim();
    }

    public String getUserImg() {
        return userImg;
    }

    public void setUserImg(String userImg) {
        this.userImg = userImg == null ? null : userImg.trim();
    }

    public Integer getUserAge() {
        return userAge;
    }

    public void setUserAge(Integer userAge) {
        this.userAge = userAge;
    }
}
